Meaning of the word "don't throw out your dirty water until you get in fresh" in English

What does "don't throw out your dirty water until you get in fresh" mean in English? Explore the meaning, pronunciation, and specific usage of this word with Lingoland.

don't throw out your dirty water until you get in fresh

US /doʊnt θroʊ aʊt jɔːr ˈdɜːrti ˈwɔːtər ʌnˈtɪl juː ɡɛt ɪn frɛʃ/
UK /dəʊnt θrəʊ aʊt jɔː ˈdɜːti ˈwɔːtər ʌnˈtɪl juː ɡɛt ɪn frɛʃ/
"don't throw out your dirty water until you get in fresh" picture

Idiom

do not discard something you already have until you are certain of obtaining something better to replace it

Example:
I know you hate your current job, but don't throw out your dirty water until you get in fresh; wait until you have a signed contract elsewhere.
He decided to keep his old car running because don't throw out your dirty water until you get in fresh applies when the market is this expensive.